<template>
  <div class="nav-cotain">
    <van-nav-bar class="page-nav-bar" :left-arrow="showArrow" @click-left="$router.back()">
      <!-- 左侧插槽 -->
      <div slot="left">
        <slot name="left"></slot>
      </div>
      <!-- 标题插槽 -->
      <div slot="title">
        <slot name="title"></slot>
      </div>
      <!-- 右侧插槽 -->
      <div slot="right">
        <slot name="right"></slot>
      </div>
    </van-nav-bar>
  </div>
</template>

<script>
export default {
  name: 'myNav',

  props: {
    // 控制显示左箭头标识
    showArrow: {
      type: Boolean,
      default: false
    }
  }
}
</script>

<style>
</style>
